import { NgModule } from '@angular/core';
import { RouterModule, Routes } from '@angular/router';

import { CallbackComponent } from './callback.component';
import { UserLoginComponent } from './login/login.component';
import { UserRegisterResultComponent } from './register-result/register-result.component';
import { UserRegisterComponent } from './register/register.component';

const routes: Routes = [
  // passport
  {path: 'login',component: UserLoginComponent,data: { title: '登录', titleI18n: 'app.login.login' },},
  {path: 'register',component: UserRegisterComponent,data: { title: '注册', titleI18n: 'app.register.register' },},
  {path: 'register-result',component: UserRegisterResultComponent,data: { title: '注册结果', titleI18n: 'app.register.register' },},
  // 单页不包裹Layout
  { path: 'passport/callback/:type', component: CallbackComponent },
];

@NgModule({
  imports: [RouterModule.forChild(routes)],
  exports: [RouterModule],
})
export class PassportRoutingModule { }
